TF Learn

by: Panagiotis Petridis, 8 years ago


So today I stumbled across TF learn which is a Higher level API for TensorFlow. The syntax looks a bit like sci-kit learn and looks pretty simple. What do you think? Is it any good?

Here's the link for the TF Learn website:
http://tflearn.org/

and here is a coding example from the site:

# Classification
tflearn.init_graph(num_cores=8, gpu_memory_fraction=0.5)

net = tflearn.input_data(shape=[None, 784])
net = tflearn.fully_connected(net, 64)
net = tflearn.dropout(net, 0.5)
net = tflearn.fully_connected(net, 10, activation='softmax')
net = tflearn.regression(net, optimizer='adam', loss='categorical_crossentropy')

model = tflearn.DNN(net)
model.fit(X, Y)


I don't know it seems really simple to me. I think that it might also help others write TensorFlow code if they are getting a bit confused with it's current syntax. They also have some tutorials on the TF Learn website.

To use it you just import TensorFlow:
import tensorflow as tf


And then the TF Learn API as such:
from tensorflow.contrib import learn




You must be logged in to post. Please login or register an account.



Thanks for sharing. There's also skflow that is very similar. Haven't used either enough to justify recommending one or the other, however. Worth checking out for sure though.

-Harrison 8 years ago

You must be logged in to post. Please login or register an account.